home *** CD-ROM | disk | FTP | other *** search
- Path: mail2news.demon.co.uk!genesis.demon.co.uk
- From: Lawrence Kirby <fred@genesis.demon.co.uk>
- Newsgroups: comp.lang.c
- Subject: Re: End of File
- Date: Sun, 28 Jan 96 22:23:57 GMT
- Organization: none
- Message-ID: <822867837snz@genesis.demon.co.uk>
- References: <4edr5q$8fi@baloo.pipex-sa.net>
- Reply-To: fred@genesis.demon.co.uk
- X-NNTP-Posting-Host: genesis.demon.co.uk
- X-Newsreader: Demon Internet Simple News v1.27
- X-Mail2News-Path: genesis.demon.co.uk
-
- In article <4edr5q$8fi@baloo.pipex-sa.net>
- Unregistered@dial.pipex.co.za "Unregistered" writes:
-
- >How does one set the file pointer to end of file on a binary file in C.
-
- fseek(fp, SEEK_END, 0);
-
- While the standard doesn't require an implementation to support SEEK_END
- on a binary file this is the most portable method (short of reading the
- file until you hit an EOF condition).
-
- --
- -----------------------------------------
- Lawrence Kirby | fred@genesis.demon.co.uk
- Wilts, England | 70734.126@compuserve.com
- -----------------------------------------
-